<?php

use Illuminate\Support\Facades\Route;
use App\Http\Controllers\HomeController;
use App\Http\Controllers\JobController;
use App\Http\Controllers\settingcontroller\DawnSettingController;
use App\Http\Controllers\settingcontroller\LogSettingController;
use App\Http\Controllers\pushcontroller\PushController;


// 打卡任务设置
Route::prefix('api')->middleware('auth')->group(function () {
    Route::get('/dawnSetting', [DawnSettingController::class, 'getDawnSetting']);
    Route::post('/dawnSetting', [DawnSettingController::class, 'saveDawnSetting']);
});

// 日志任务设置
Route::prefix('api')->middleware('auth')->group(function () {
    Route::get('/logSetting', [LogSettingController::class, 'getLogSetting']);
    Route::post('/logSetting', [LogSettingController::class, 'saveLogSetting']);
});

Route::prefix('api/push')
    ->group(function () {
        Route::post('/msgCallback', [PushController::class, 'msgCallback']);
        Route::post('/userCallback', [PushController::class, 'userCallback']);
        Route::post('/friendCallback', [PushController::class, 'friendCallback']);
        Route::post('/getAccessKey', [PushController::class, 'getAccessKey']);
        Route::get('/getQrCode', [PushController::class, 'getQrCode']);
        Route::get('/getWechatQrCode', [PushController::class, 'getWechatQrCode']);
        Route::get('/getfriendlist', [PushController::class, 'getfriendlist']);
        Route::post('/delfriend', [PushController::class, 'delfriend']);
        Route::get('/token', [PushController::class, 'getPushToken']);
        Route::post('/token', [PushController::class, 'updatePushToken']);
        Route::post('/sendTestMsg', [PushController::class, 'sendTestMsg']);
});


